﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Tour.BLL;
using Tour.DAL;

public partial class Hotel_RoomDetail : System.Web.UI.Page
{
    public string TextId { get; set; }
    protected void Page_Load(object sender, EventArgs e)
    {
        GetPropertyFromQueryString();
        LoadDataRoomType();
        LoadDataRoom();
    }
    void GetPropertyFromQueryString()
    {
        if (Request["TextId"] != null)
            TextId = CommonHelper.QueryString("TextId");
        else
            TextId = null;
    }
    void LoadDataRoomType()
    {
        rptRoomType.DataSource = TblRoomTypeManager.CreateInstant().SelectTblRoomTypeBy(null, null, null, TextId, true, true, "CreatedDate", "DESC");
        rptRoomType.DataBind();
    }
    void LoadDataRoom()
    {
        int TotalRow = 0;
        rpt.DataSource = TblRoomManager.CreateInstant().SelectTblRoomBy(null, null, TextId, "", null,null, out TotalRow, "CreatedDate", "DESC");
        rpt.DataBind();
    }
}